/**
 * jims
 */
package com.jims.master.modules.doctor.medicalService.entity;

import com.fasterxml.jackson.annotation.JsonFormat;
import com.google.common.collect.Lists;
import com.jims.master.common.persistence.DataEntity;
import com.jims.master.modules.base.medicalService.entity.SDefaultServe;
import org.apache.commons.lang3.StringUtils;
import org.apache.commons.lang3.time.DateUtils;
import org.hibernate.validator.constraints.Length;

import java.text.ParseException;
import java.util.Date;
import java.util.List;

/**
 * 医生提供的服务日程表Entity
 * @author 医生提供的服务日程表
 * @version 2017-05-07
 */
public class SDoctorPlan extends DataEntity<SDoctorPlan> {
	
	private static final long serialVersionUID = 1L;
	private String doctorId;		// 医生Id
	private String serviceId;		// 服务Id
	private String serviceName;		// 服务Id
	private Date serviceDate;		// 服务时间
	private String serviceDateStr;		// 服务时间字符串
	private String serviceWeekStr;		// 服务时间字符串
	private String timeType;		// 服务时间类型
	private String timeTypeLabel;
	private String personNum;		// 服务人数
	private int orderedNum;		// 服务人数
	private int planNum;		// 预约人数

	public int getPlanNum() {
		return planNum;
	}

	public void setPlanNum(int planNum) {
		this.planNum = planNum;
	}

	public SDoctorPlan() {
		super();
	}

	public SDoctorPlan(String id){
		super(id);
	}

	@Length(min=0, max=64, message="医生Id长度必须介于 0 和 64 之间")
	public String getDoctorId() {
		return doctorId;
	}

	public void setDoctorId(String doctorId) {
		this.doctorId = doctorId;
	}
	
	@Length(min=0, max=64, message="服务Id长度必须介于 0 和 64 之间")
	public String getServiceId() {
		return serviceId;
	}

	public void setServiceId(String serviceId) {
		this.serviceId = serviceId;
	}
	@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
	public Date getServiceDate() {
		return serviceDate;
	}

	public void setServiceDate(Date serviceDate) {
		this.serviceDate = serviceDate;
	}

	@Length(min=0, max=10, message="服务时间类型长度必须介于 0 和 10 之间")
	public String getTimeType() {
		return timeType;
	}

	public void setTimeType(String timeType) {
		this.timeType = timeType;
	}
	
	@Length(min=0, max=10, message="服务人数长度必须介于 0 和 10 之间")
	public String getPersonNum() {
		return personNum;
	}

	public void setPersonNum(String personNum) {
		this.personNum = personNum;
	}

	private List<SDoctorPlan> oneDayPlans = Lists.newArrayList();

	public List<SDoctorPlan> getOneDayPlans() {
		return oneDayPlans;
	}

	public void setOneDayPlans(List<SDoctorPlan> oneDayPlans) {
		this.oneDayPlans = oneDayPlans;
	}

	public String getServiceDateStr() {
		return serviceDateStr;
	}

	public void setServiceDateStr(String serviceDateStr) {
		this.serviceDateStr = serviceDateStr;
	}

	public String getServiceName() {
		return serviceName;
	}

	public void setServiceName(String serviceName) {
		this.serviceName = serviceName;
	}

	public String getTimeTypeLabel() {
		return timeTypeLabel;
	}

	public void setTimeTypeLabel(String timeTypeLabel) {
		this.timeTypeLabel = timeTypeLabel;
	}

	public int getOrderedNum() {
		return orderedNum;
	}

	public void setOrderedNum(int orderedNum) {
		this.orderedNum = orderedNum;
	}

	public String getServiceWeekStr() {
		return serviceWeekStr;
	}

	public void setServiceWeekStr(String serviceWeekStr) {
		this.serviceWeekStr = serviceWeekStr;
	}
}